package com.blog.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.blog.entity.Comment;

import java.util.List;

public interface CommentService extends IService<Comment> {
    Comment createComment(Comment comment);
    
    Comment updateComment(Comment comment);
    
    void deleteComment(Long id);
    
    Comment findById(Long id);
    
    List<Comment> findByArticleId(Long articleId);
    
    IPage<Comment> findByArticleId(Long articleId, Page<Comment> page);
    
    List<Comment> findByUserId(Long userId);
    
    IPage<Comment> findByUserId(Long userId, Page<Comment> page);
    
    long getCommentCount();
} 